package com.liang.text3;

public class TestAnimal {
    public static void main(String[] args) {
        Dog dog = new Dog("哈士奇",2,97.2);
        System.out.println(dog.getName()+"..."+dog.getAge()+"..."+dog.getHeight());
        dog.eat();
        dog.drink();

        System.out.println("-------");

        Cat cat = new Cat();
        cat.setAge(1);
        cat.setName("折耳猫");
        System.out.println(cat.getName()+"..."+cat.getAge());
        cat.eat();
        cat.drink();

        System.out.println("-------");

        JumpDog jumpDog = new JumpDog("杂技狗",3);
        System.out.println(jumpDog.getName()+"..."+jumpDog.getAge());
        jumpDog.eat();
        jumpDog.drink();
        jumpDog.jumping();

        System.out.println("------");

        JumpCat jumpCat = new JumpCat("杂技猫",3);
        System.out.println(jumpCat.getName()+"..."+jumpCat.getAge());
        jumpCat.eat();
        jumpCat.drink();
        jumpCat.jumping();
        jumpCat.swimming();
        Jumping.playing();
    }
}
